class Dog{
  void shout(){
    print('Wang wang wang !');
  }
}

class Person extends Dog{
  String name='';
  int age=0;
  String gender='';
  void work(){
    print('Work...');
  }
}

void main(){
  var person;
  person?.work();
  person = new Person();
  if(person is Person){
    person.work();
  }
  person..name='Tom'
        ..age=19..gender='Male';
  person as Dog;
  person.shout();
}
